
function logged(value, context) {
  console.log('value: ', value)
  console.log('context: ', context)
  if(context.kind === 'class') {
    return class extends value {
      constructor(...args) {
        super(...args)
        console.log(`constructing an instance of ${context.name} with arguments ${args.join(',')}`);
        
      }
    }
  }
}

// @ts-ignore
@logged
class Class {
  constructor(public a: number) {

  }
}
new Class(1)
export {}